package com;

import cn.hutool.core.bean.BeanUtil;
import com.care.vo.Comments;
import com.go2.shipping.common.encrypt.AES;
import com.yuhang.demo.PmTest;
import com.yuhang.demo.util.OrderPayDto;
import com.yuhang.demo.util.PayType;
import com.yuhang.demo.util.PostUtil;
import org.apache.http.HttpEntity;
import org.apache.http.NameValuePair;
import org.apache.http.client.ClientProtocolException;
import org.apache.http.client.config.RequestConfig;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.mime.MultipartEntityBuilder;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.http.message.BasicNameValuePair;

import java.io.*;
import java.util.*;

/**
 * @user yuhang
 * @desc
 * @since 2021/11/15
 */
public class MicroTest {

//    private static String api = "http://localhost:8082";
    private static String api = "http://appservice.go2b2b.com";

//    private static String api = "https://sellerapp.ximgs.net";
    static String token = "DspBkJa4IpigMAlXnSnq4meXHI+MOr/4MOJ2UQh4u52C0wg9lpwsUeu2mKvyl8Js";
    static AES aes = new AES("2016.01_go2plus_chengdu_china");

    public static void main(String[] args) throws Exception {
        long a = System.currentTimeMillis();
//        String result =hotword();
//          String result =getValiCode();
//        String result = phoneVali();
//        String result = checkVCode();

//         String result = oneClickLogin();
        String result = login();
//        String result=accountCancel();
//        String result = loginTest();
//        String result = createOrder();
//        String result =orderList();

//         String result = orderEdit();
//        String result =queryItemByOuterIds();
//        String result = updateOrder();
//        String result = loadSupplierInfo();
//        String result =loadDsOrSupplierInfo();

//        String result =queryOfficialDs();
//        String result =queryOrderIn();
//        String result =payInfo();

//        String result=orderDetail();
//        String result= getRefundShowTime();
//         String result=cancelOrder();
//         String result =transaction();

//        String result = orderPay();

//        String result = deposit();
//        String result = returnOrder();
//        String result = getTakeTracByOrderId();
//        for (int i = 0; i < 10000; i++) {
//
//                String        result = getAllDictArea();
//
//
//        }
//        String result =getRecevicerList();
//        String result =seleOrderInfoCountNum();
//        String result = getUserInfo();


//        String result=getRecommendProducts();
//        String result=categoryProperties();
//        String result = goods();

//        long a = System.currentTimeMillis();
//        String result= todayTake();
//        String result = pub();
//        String result = hot();
//        String result = goods();
//        String result = lowerPrice();
//         String result =getPubBaseNum();
//           String result = searchOrigin();
//           String result=brands();
//        String result = searchOrigin();

//        String result =  searchRecommend();
//        String result =pcollect();
//        String result=channelList();
//        String result=followList();
//        String result =banner();
//          System.out.println(result);
//        String result= baseInfo();
//        String result=updateLoginPwd();
//        String result=shopList();
//          String result=dictExpress();
//        String result=followList();
//        String result=getOrderMessage();
//        String result=addWaitPub();

//        String result= appStartUp();
//        String result=  getHotMessage();
//        String result=shoppingChannelList();
//        String result=cube100();
//        String result= category();

//          String result =getRandomsPubMsg();
//        String result =getBindShops();
//        String result =getPubShops();
//        String result =  refundList();
//        String result =getProductPubDownDetails();
//        String result=checkPublish();
//        String result=vip();
//         String result=getMapSupplier();
//        String result= followRecommendList();
//        String result= transferPay();
//        String result =orderNotice();
//        String result =getBannerUrl();
//        String result =pcollectCancel();
//         feedBackAdd();
//        modifyUserImg();
//        String result=updateSender();
//     String result=loadSingleGsbItem();
//        String result=listMessage();
//        String result=shoppingChannelList();

//        String result = appStartUp();
//        String result=getHotMessage();

//        String result=getTargetUserInfo();
//        sysnIds();
//        String result= getBannerUrl();

//        String result= listForOrder();
//        String result=downloadCheck();
//        String result=detail();

//        sysnIds();
//        String result =listForOrder();

//        String result = queryOfficialDs();
//        String result =identity();
//        String result=bindShopConfig();
//        String result=tbOnkey();
//        String result=unreadTotal();
//        String result =printJson();
//        String result= getProductCommentByProductId();
//        String result=getProductCommentProps();
//        String result=addComments();
//        String result=printLog();
//        String result=getPubItem();
//        String result=categoryProperties();
//        String result=downProductImagesCount();
//        String result=downProductVideo();
//        String result=getRangeProperties();
//        String result=getCubeCategorys();
//        String result=getCubeData();
//        String result=getChannel();
//        String result=getChannelData();
//        String result=getData();
//        String result=getImageSeachData();
//        String result=saveFeedBack();
//        String result=downProductImages();
//          String result=saveHotFeedBack();
//        String result=getHomeCategory();
//        String result=httpPostBody();
        System.out.println(result);
//        xxx();
        //15388341391
        //7649
        //名港
        //e3hw
        //android
        System.out.println(System.currentTimeMillis() - a);
    }


    private static String httpPostBody() throws IOException {

        String url = api + "/site/business/lessons/page";
        String json = "{\"pageNo\":2,\n" +
                " \"pageSize\":20}";
        return PostUtil.httpPostBody(url, json);
    }

    private static String getData() throws Exception {
        String url = api + "/app/hot/getData";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getHomeCategory() throws Exception {
        String url = api + "/app/home/getHomeCategory";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("remark", "12313"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String saveHotFeedBack() throws Exception {
        String url = api + "/api/cube/saveHotFeedBack";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("remark", "12313"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String downProductImages() throws Exception {
        String url = api + "/api/app/pub/downProductImages?productId=2793194";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("remark", "12313"));
        return PostUtil.httpGetWithHeader(url, new HashMap<>(), token);
    }

    private static String saveFeedBack() throws Exception {
        String url = api + "/api/cube/saveFeedBack";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("remark", "12313"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String getImageSeachData() throws Exception {
        String url = api + "/cube/getImageSeachData";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("id", "27560"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getChannelData() throws Exception {
        String url = api + "/cube/getChannelData";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("time", "2022-11-19"));
        formparams.add(new BasicNameValuePair("channel", "dy"));
        formparams.add(new BasicNameValuePair("cycle", "day"));
        formparams.add(new BasicNameValuePair("pageNo", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getChannel() throws Exception {
        String url = api + "/cube/getChannel";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "4"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String getCubeData() throws Exception {
        String url = api + "/cube/getCubeData";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "2"));
//        formparams.add(new BasicNameValuePair("sex", "VT"));
//        formparams.add(new BasicNameValuePair("age", "ZXT"));
        formparams.add(new BasicNameValuePair("pageNo", "1"));
        formparams.add(new BasicNameValuePair("pageSize", "20"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getCubeCategorys() throws Exception {
        String url = api + "/cube/getCubeCategorys";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("sex", "VT"));
        formparams.add(new BasicNameValuePair("age", "ZDT"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getRangeProperties() throws Exception {
        String url = api + "/cube/getRangeProperties";
        return PostUtil.httpGetWithHeader(url, new HashMap<>(), token);
    }

    private static String downProductVideo() throws Exception {
        String url = api + "/api/app/pub/downProductVideo?productId=2818590";
        return PostUtil.httpGetWithHeader(url, new HashMap<>(), token);
    }

    private static String downProductImagesCount() throws Exception {
        String url = api + "/api/app/pub/downProductImagesCount?productId=2818590";
        return PostUtil.httpGetWithHeader(url, new HashMap<>(), token);
    }

    private static String getPubItem() throws Exception {
        String url = api + "/api/data/getPubItem";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "2954004"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String printLog() throws Exception {
        String url = api + "/log/prinjson";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("jsons", "[{\"id\":\"1665193395583634595\",\"user_id\":\"910195\",\"page\":\"ProductClasspage\",\"create_time\":\"1665193395583\",\"activity_name\":\"click_category_choose\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.2.5\",\"platform_type\":\"vivo-vivo X21A\",\"ident\":\"1ceea5680ddbcf98\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"tab\\\":\\\"all\\\",\\\"properties\\\":\\\"21-314\\\"}\",\"phonePaste\":\"1580309694\",\"product_id\":null},{\"id\":\"1665193398496804864\",\"user_id\":\"910195\",\"page\":\"ProductClasspage\",\"create_time\":\"1665193398497\",\"activity_name\":\"click_category_choose\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.2.5\",\"platform_type\":\"vivo-vivo X21A\",\"ident\":\"1ceea5680ddbcf98\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"tab\\\":\\\"all\\\",\\\"properties\\\":\\\"21-736\\\"}\",\"phonePaste\":\"1580309694\",\"product_id\":null}]"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String categoryProperties() throws Exception {
        String url = api + "//search/categoryProperties";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getProductCommentByProductId() throws Exception {
        String url = api + "/api/app/comment/getProductCommentByProductId";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "3282154"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getProductCommentProps() throws Exception {
        String url = api + "/api/app/comment/getProductCommentProps";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String addComments() throws Exception {
        String url = api + "/api/app/comment/addProductComment";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "3231278"));
        formparams.add(new BasicNameValuePair("goodsTag", "3"));
        formparams.add(new BasicNameValuePair("serviceTag", "13"));
        formparams.add(new BasicNameValuePair("score", "3"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String unreadTotal() throws IOException {
        String url = api + "/api/app/SellerMessage/unreadTotal";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String printJson() throws IOException {
        String json = " [{\"id\":\"165053383459014\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533834590\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=PDD\\\"}\",\"phonePaste\":\"\",\"product_id\":null},{\"id\":\"165053383647564\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533836475\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=TAOBAO\\\"}\",\"phonePaste\":\"\",\"product_id\":null},{\"id\":\"165053385452594\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533854525\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=TAOBAO\\\"}\",\"phonePaste\":\"\",\"product_id\":null},{\"id\":\"165053385798367\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533857983\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=TAOBAO\\\"}\",\"phonePaste\":\"\",\"product_id\":null},{\"id\":\"165053386034329\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533860343\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=PDD\\\"}\",\"phonePaste\":\"\",\"product_id\":null},{\"id\":\"165053386222858\",\"user_id\":\"304824\",\"page\":\"SalesHomeShow\",\"create_time\":\"1650533862228\",\"activity_name\":\"click_platform\",\"ip_address\":\"\",\"page_channel\":\"e3e3_b2\",\"app_version\":\"4.0.8\",\"platform_type\":\"Xiaomi-M2011K2C\",\"ident\":\"886675b6eda6765b\",\"user_channel\":\"e3e3\",\"parameter\":\"{\\\"product_id\\\":\\\"2818402\\\",\\\"other\\\":\\\"platform=TAOBAO\\\"}\",\"phonePaste\":\"\",\"product_id\":null}]";
        String url = api + "/log/prinjson";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("jsons", json));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String tbOnkey() throws IOException {
        String url = api + "/api/app/pub/tbonekeypublish";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "2719876"));
        formparams.add(new BasicNameValuePair("shopId", "250246"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String bindShopConfig() throws IOException {
        String url = api + "/api/app/SupplierCustomers/bindShopConfig";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpGetWithHeader(url, new HashMap<>(), token);
    }

    private static String identity() throws IOException {
        String url = api + "/api/app/2b/shop/identity";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String detail() throws IOException {
        String url = api + "/api/app/2b/auth/detail";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String downloadCheck() throws IOException {
        String url = api + "/api/vip/video/download/check?productId=3377456";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "3377456"));


        return PostUtil.httpGetWithr(url, formparams, token);
    }

    private static String getTargetUserInfo() throws IOException {
        String url = api + "/api/app/user/getTargetUserInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("targetUserId", "685507"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String listMessage() throws IOException {
        String url = api + "/api/app/SellerMessage/listMessage";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("messageType", "product"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String loadSingleGsbItem() throws IOException {
        String url = api + "/api/app/2b/order/loadSingleGsbItem";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("itemId", "46589968"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    public static void xxx() throws IOException {

        String ids = "2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,12572022643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202,2643319,2809384,2727171,2797657,2182671,2784198,2778251,2778888,2758219,2756543,2729383,2762969,2755645,2749289,2749211,2752426,2753008,2639274,2641863,2752622,2750604,2745125,2572452,2580307,2597171,2554834,2556346,2554642,2564191,2474690,2531719,2364999,2528340,2526793,2478149,2147091,2489937,2503242,2505346,2489930,2501641,2497203,2497217,2491167,2427345,2481345,2476234,2472608,2475695,2405864,2467020,2467416,2466995,2472020,2467004,2444704,2477921,2477919,2410766,2470190,2457806,2465335,2468375,2470131,2475151,2467605,2471278,2465807,2463164,2470255,2463548,2466943,2473101,2463832,2466199,2466207,2466122,2464875,2466270,2466169,2466188,2466211,2466246,2466193,2464652,2468600,2463828,2455516,2348263,2396424,2396430,2468578,2458276,2438412,2442746,2442760,2442744,2435455,2425999,2425992,2426088,2426015,2293986,2411063,2400497,2396200,2396163,2396169,2334189,2332223,2328435,2334193,2306243,2300906,2303691,2271517,1257202";

        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        long a = System.currentTimeMillis();
        String result = PostUtil.httpPostWithHeader(String.format("http://192.168.10.37:16100/go2.cn/cache/product/%s", "2614527"), formparams, token);
        System.out.println(System.currentTimeMillis() - a);

    }

    public static void sysnIds() throws IOException {
        String url = "http://app.go2b2b.com/common/sync/product/go2/%s";

//       Integer[] a =new Integer[]{2793194,2796267,2797355,2799529,2801897,2811949,2794018,2811171,2793696,2806753,2798136,2811262,2800947,2796209,2804721,2811189,2812789,2808650,2793163,2801928,2804238,2808256,2795649,2804934,2808711,2793370,2810459,2801048,2800670,2813919,2813983,2794972,2809756,2799888,2810455,2808852,
//               2824747,2823213,2824812,2824675,2823970,2823718,2824058,2823546,2823929,2823225,2822840,2823167,2823998,2824445,2823921,2824241,2818935,2822838,2823028,2823412,2824052,2823563,2818569,2817678,2820239,2824079,2824717,2823298,2823170,2823111,2824580,2823300,2823965,2823005,2802130,2823959,
//               2808170,2808168,2799977,2800553,2804718,2807214,2799532,2811171,2800294,2795640,2793593,2805951,2796476,2807164,2800179,2796209,2810417,2811249,2806710,2808631,2799886,2810446,2811021,2808256,2804935,2800670,2810206,2794972,2809756,2797395,2803792,2809937,2806934,2803223,2799508,2808852,
//               2215073,2044636,2210850,2234918,2589794,2129190,2289317,2585582,2571820,2204909,2580715,2143535,2182901,2596090,2187391,2204478,2605954,2617473,2152460,2213007,2559432,2092331,1461665,2213270,2585168,2554846,2580382,2147674,2044771,2099420,2332829,
//               2604517,2559919,2551471,2634402,2550250,1666249,2429296,2126582,2276090,2274619,2439804,2375609,2617082,2655157,2227519,1952895,2129220,2560643,2562560,2443476,2636249,2620052,1790764,2646943,1989734,2213209,2188058,2606043,1912736,2565593,2651735,
//               2205665,1819422,2572783,2752480,2753571,2723363,2616811,2687012,2724327,2717560,2701626,2228278,2648060,2753008,2753009,2579779,2736591,2568847,2632451,2634437,2755589,2609366,2734875,2606482,2295381,2594719,2148954,2740563,1658020,2562969,2752150
//       };
        Integer[] a = new Integer[]{2614527};
//       Integer[] a=new Integer[]{2809384,2823721,2824233,2824749,2823724,2824236,2819619,2821154,2821666,2823712,2824231,2824230,2824228,2824251,2821177,2824248,2823742,2824252,2824243,2803248,2823729,2824247,2824244,2824713,2823176,2823183,2823695,2819084,2786822,2824216,2818590,2823710,2821660,2823196,2822161,2823696,2820118,2816619,2822250,2824810,2824809,2818671,2822767,2817647,2824814,2819693,2822242,2823776,2821735,2822247,2822246,2815610,2819193,2822776,2220149,2799230,2823295,2805887,2811519,2823294,2811516,2816125,2822268,2823797,2824271,2824783,2823758,2824270,2816589,2823756,2822210,2815040,2820673,2822215,2823238,2755652,2819653,2822212,2636892,2823262,2823774,2822224,2819158,2810452,2820267,2822827,2812591,2823341,2813602,2822819,2823335,2824359,2820283,2800831,2808509,2817715,2822833,2824368,2822836,2807438,2811022,2823311,2816140,2823309,2823299,2821762,2823302,2821764,2750617,2823828,2823919,2816239,2816751,2823405,2823917,2824418,2821857,2823393,2824417,2820832,2823904,2823419,2823934,2126582,2824444,2822899,2823922,2823927,2823926,2138879,2821838,2823374,2815171,2823872,2670296,2816733,2822867,2806998,2803415,2823978,2821417,2823470,2820908,2821932,2823980,2815266,2820386,2823458,2823969,2823975,2817828,2822456,2823997,2822972,2824498,2820912,2821431,2822455,2813239,2819381,2821941,2823989,2822964,2824500,2824459,2823946,2816268,2824451,2823938,2810116,2823450,2823960,2823967,2822942,2821405,2822941,1790764,2822931,2823443,2822418,2823953,2188058,2822422,2820373,2823445,2816789,2820457,2813292,2818924,2823532,2824034,2820455,2810724,2824037,2823032,2817919,2820478,2823549,2823538,2810736,2823025,2823537,2811766,2823029,2823541,2821963,2823499,2822985,2822991,2823503,2821953,2824513,2745154,2819392,2823495,2820955,2817886,2823517,2819420,2818898,2823504,2824535,2816855,2822486,2782548,2824021,2823082,2824618,2824104,2823087,2818477,2809762,2815394,2815395,2814373,2816955,2819519,2824639,2822589,2824624,2823051,2149762,2808200,2823055,2823053,2823052,2820483,2817923,2820992,2808710,2819975,2815879,2823558,2817924,2823557,2824090,2775961,2821533,2816413,2823569,2809751,2822549,2811882,2815466,2823146,2823145,2823657,2737133,2821615,2821614,2823662,2824174,2823651,2823648,2550250,2817508,2819557,2822628,2823652,2823161,2823673,2819070,2819068,2824691,2815473,2823664,2814453,2811342,2820557,2823117,2819011,2769345,2807745,2817498,2823131,2823643,2780635,2821594,2823642,2823129,2824664,2813918,2817502,2823132,2823123,2822098,2822097,2821591,2821589,2822101};
        for (int i = 0; i < a.length; i++) {
            List<NameValuePair> formparams = new ArrayList<NameValuePair>();
            PostUtil.httpPostWithHeader(String.format(url, a[i]), formparams, token);
        }

        System.out.println(a.length);
    }

    public static void modifyUserImg() throws ClientProtocolException, IOException {
        CloseableHttpClient httpClient = HttpClientBuilder.create().build();
        CloseableHttpResponse httpResponse = null;
        RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(200000).setSocketTimeout(200000000).build();
        HttpPost httpPost = new HttpPost(api + "/api/app/user/modifyUserImg");
        httpPost.setConfig(requestConfig);
        httpPost.addHeader("token", token);
        MultipartEntityBuilder multipartEntityBuilder = MultipartEntityBuilder.create();

        File file = new File("D://1.jpg");
        //当设置了setSocketTimeout参数后，以下代码上传PDF不能成功，将setSocketTimeout参数去掉后此可以上传成功。上传图片则没有个限制
        multipartEntityBuilder.addBinaryBody("img", file);
        multipartEntityBuilder.addTextBody("type", "other");
        multipartEntityBuilder.addTextBody("content", "other");
        HttpEntity httpEntity = multipartEntityBuilder.build();
        httpPost.setEntity(httpEntity);
        httpResponse = httpClient.execute(httpPost);
        HttpEntity responseEntity = httpResponse.getEntity();
        int statusCode = httpResponse.getStatusLine().getStatusCode();
        if (statusCode == 200) {
            BufferedReader reader = new BufferedReader(new InputStreamReader(responseEntity.getContent()));
            StringBuffer buffer = new StringBuffer();
            String str = "";
            while ((str = reader.readLine()) != null) {
                buffer.append(str);
            }

            System.out.println(buffer.toString());
        }
        System.out.println(httpResponse.getEntity());
        httpClient.close();
        if (httpResponse != null) {
            httpResponse.close();
        }

    }


    public static void feedBackAdd() throws ClientProtocolException, IOException {
        CloseableHttpClient httpClient = HttpClientBuilder.create().build();
        CloseableHttpResponse httpResponse = null;
        RequestConfig requestConfig = RequestConfig.custom().setConnectTimeout(200000).setSocketTimeout(200000000).build();
        HttpPost httpPost = new HttpPost(api + "/api/app/user/feedBackAdd");
        httpPost.setConfig(requestConfig);
        httpPost.addHeader("token", token);
        MultipartEntityBuilder multipartEntityBuilder = MultipartEntityBuilder.create();

        File file = new File("D://1.jpg");
        //当设置了setSocketTimeout参数后，以下代码上传PDF不能成功，将setSocketTimeout参数去掉后此可以上传成功。上传图片则没有个限制
        multipartEntityBuilder.addBinaryBody("imgs", file);
        multipartEntityBuilder.addTextBody("type", "other");
        multipartEntityBuilder.addTextBody("content", "other");
        HttpEntity httpEntity = multipartEntityBuilder.build();
        httpPost.setEntity(httpEntity);
        httpResponse = httpClient.execute(httpPost);
        HttpEntity responseEntity = httpResponse.getEntity();
        int statusCode = httpResponse.getStatusLine().getStatusCode();
        if (statusCode == 200) {
            BufferedReader reader = new BufferedReader(new InputStreamReader(responseEntity.getContent()));
            StringBuffer buffer = new StringBuffer();
            String str = "";
            while ((str = reader.readLine()) != null) {
                buffer.append(str);
            }

            System.out.println(buffer.toString());
        }
        System.out.println(httpResponse.getEntity());
        httpClient.close();
        if (httpResponse != null) {
            httpResponse.close();
        }

    }


    private static String updateSender() throws IOException {
        String url = api + "/api/app/user/updateSender";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("name", "郭可胜"));
        formparams.add(new BasicNameValuePair("mobile", "15882101211"));
        formparams.add(new BasicNameValuePair("address", "哈哈"));
        formparams.add(new BasicNameValuePair("provinceName", "四川"));
        formparams.add(new BasicNameValuePair("provinceId", "27"));
        formparams.add(new BasicNameValuePair("cityName", "成都"));
        formparams.add(new BasicNameValuePair("cityId", "2294"));
        formparams.add(new BasicNameValuePair("countyName", "2313"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String transferPay() throws IOException {
        String url = api + "/api/app/pay/transferPay";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderNo", "2112167567052"));
        formparams.add(new BasicNameValuePair("type", "BALANCE"));
        formparams.add(new BasicNameValuePair("selectType", "WAP"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String pcollectCancel() throws IOException {
        String url = api + "/api/app/2b/pcollect/cancel";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("targetId", "17322205"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String getBannerUrl() throws IOException {
        String url = api + "/banner/getBannerUrl";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String orderNotice() throws IOException {
        String url = api + "/api/app/2b/orderNotice";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String followRecommendList() throws IOException {
        String url = api + "/supplier/followRecommendList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getMapSupplier() throws IOException {
        String url = api + "/supplier/getMapSupplier";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("amount", "0.01"));
        formparams.add(new BasicNameValuePair("selectType", "APP"));
        formparams.add(new BasicNameValuePair("payType", "ALIPAY"));
        formparams.add(new BasicNameValuePair("vipType", "YEAR_VIP"));
        formparams.add(new BasicNameValuePair("password", "123456"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String vip() throws IOException {
        String url = api + "/api/pay/vip";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("amount", "0.01"));
        formparams.add(new BasicNameValuePair("selectType", "APP"));
        formparams.add(new BasicNameValuePair("payType", "ALIPAY"));
        formparams.add(new BasicNameValuePair("vipType", "YEAR_VIP"));
        formparams.add(new BasicNameValuePair("password", "123456"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String checkPublish() throws IOException {
        String url = api + "/api/seller/vip/checkPublish";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productId", "2790230"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getProductPubDownDetails() throws IOException {
        String url = api + "/supplier/getProductPubDownDetails/320697";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getPubShops() throws IOException {
        String url = api + "/api/app/pub/getPubShops";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getBindShops() throws IOException {
        String url = api + "/api/app/pub/getBindShops";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getRandomsPubMsg() throws IOException {
        String url = api + "/api/apppub/getRandomsPubMsg";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String category() throws IOException {
        String url = api + "/api/data/category?date=2020-03-27";
        return PostUtil.httpGetWithHeader(url, null, token);
    }

    private static String cube100() throws IOException {
        String url = api + "/api/data/cube100?date=2020-03-27";
        return PostUtil.httpGetWithHeader(url, null, token);
    }

    private static String shoppingChannelList() throws IOException {
        String url = api + "/api/app/2b/shop/shoppingChannelList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String listForOrder() throws IOException {
        String url = api + "/api/app/SupplierCustomers/listForOrder";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("sort", "uploadTime"));
        formparams.add(new BasicNameValuePair("page", "1"));
        formparams.add(new BasicNameValuePair("pageSize", "10"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getHotMessage() throws IOException {
        String url = api + "/recommend/getHotMessage";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String appStartUp() throws IOException {
        String url = api + "/appStartUp";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String addWaitPub() throws IOException {
        String url = api + "/api/app/pub/addWaitPub";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productIds", "2790230"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getOrderMessage() throws IOException {
        String url = api + "/api/app/2b/order/getOrderMessage";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("productIds", "3351148"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String dictExpress() throws IOException {
        String url = api + "/api/app/2b/order/dictExpress";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("channel", "taobao"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String shopList() throws IOException {
        String url = api + "/api/app/2b/shop/list";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("channel", "taobao"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String updateLoginPwd() throws IOException {
        String url = api + "/api/app/account/updateLoginPwd";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("oldPwd", ""));
        formparams.add(new BasicNameValuePair("newPwd", aes.encrypt("1234567")));
        formparams.add(new BasicNameValuePair("conPwd", aes.encrypt("1234567")));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String searchOrigin() throws IOException {
        String url = api + "/supplier/search/origin";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "0"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String brands() throws IOException {
        String url = api + "/supplier/brands";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "0"));
        return PostUtil.httpGetWithHeader(url, null, token);
    }

    private static String baseInfo() throws IOException {
        String url = api + "/api/app/2b/shop/baseInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String banner() throws IOException {
        String url = api + "/banner/getBannerUrl";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "0"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String xx() throws IOException {
        String str = "http://passport.3e3e.cn/api/v2/jump?from=3e3e.cn&redirectUrl=erp1.3e3e.cn";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpGet(str);
    }

    private static String followList() throws IOException {
        String url = api + "/api/app/user/followList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("pageSize", "20"));
        formparams.add(new BasicNameValuePair("pageNo", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String channelList() throws IOException {
        String url = api + "/api/app/2b/channelList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("channel", "1688"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String pcollect() throws IOException {
        String url = api + "/api/app/2b/pcollect/list";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("type", "2"));
        formparams.add(new BasicNameValuePair("viewType", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String searchRecommend() throws IOException {
        String url = api + "/supplier/search/recommend";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("area", "2002"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getPubBaseNum() throws IOException {
        String url = api + "/recommend/getPubBaseNum";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String lowerPrice() throws IOException {
        String url = api + "/recommend/lowerPrice";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        formparams.add(new BasicNameValuePair("type", "3"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String goods() throws IOException {
        String url = api + "/recommend/goods";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("page", "2"));
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String todayTake() throws IOException {
        String url = api + "/recommend/todayTake";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String hot() throws IOException {
        String url = api + "/recommend/hot";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String pub() throws IOException {
        String url = api + "/recommend/pub";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String getRecommendProducts() throws IOException {
        String url = api + "/recommend/getRecommendProducts";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String getUserInfo() throws IOException {
        String url = api + "/api/app/user/getUserInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String seleOrderInfoCountNum() throws IOException {
        String url = api + "/api/app/2b/order/seleOrderInfoCountNum";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getRecevicerList() throws IOException {
        String url = api + "/api/app/dictArea/getRecevicerList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        formparams.add(new BasicNameValuePair("pageSize", "1"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getAllDictArea() throws IOException {
        String url = api + "/api/app/dictArea/getAllDictArea";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getTakeTracByOrderId() throws IOException {
        String url = api + "/api/app/2b/order/getTakeTracByOrderId";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderId", "6379835"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String returnOrder() throws IOException {
        String url = api + "/api/app/2b/order/returnOrder";

        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderId", "6378238"));
        formparams.add(new BasicNameValuePair("itemIds", "7676519"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String orderPay() throws IOException {
        String url = api + "/api/app/pay/orderPay";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("amount", "34.2"));
        formparams.add(new BasicNameValuePair("orders", "6378224"));
        formparams.add(new BasicNameValuePair("pwd", aes.encrypt("123456")));
        formparams.add(new BasicNameValuePair("type", "ALIPAY"));//ALIPAY,BALANCE
        formparams.add(new BasicNameValuePair("comments", ""));
        formparams.add(new BasicNameValuePair("selectType", "WAP"));

        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String deposit() throws IOException {
        String url = api + "/api/app/pay/deposit";

        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("fee", "1"));
        formparams.add(new BasicNameValuePair("orders", "6378224"));
        formparams.add(new BasicNameValuePair("selectType", "WAP"));

        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String cancelOrder() throws IOException {
        String url = api + "/api/app/2b/order/cancelOrder";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderId", "6378213"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String getRefundShowTime() throws IOException {
        String url = api + "/api/app/2b/order/getRefundShowTime";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderId", "6378213"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String orderDetail() throws IOException {
        String url = api + "/api/app/2b/order/orderDetail";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderId", "7812996"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String payInfo() throws IOException {
        String url = api + "/api/app/2b/order/payInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderIds", "6378213"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String queryOrderIn() throws IOException {
        String url = api + "/api/app/2b/order/queryOrderIn";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("supplierId", "305006"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String queryOfficialDs() throws IOException {
        String url = api + "/api/app/2b/order/queryOfficialDs";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("supplierId", "305006"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String loadSupplierInfo() throws IOException {
        String url = api + "/api/app/2b/order/loadSupplierInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("supplierId", "305006"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String loadDsOrSupplierInfo() throws IOException {
        String url = api + "/api/app/2b/order/loadDsOrSupplierInfo";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("supplierId", "506443"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String updateOrder() throws IOException {
        String url = api + "/api/app/2b/order/updateOrder";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        File f = new File(System.getProperty("user.dir") + System.getProperty("file.separator") + "orderUpdate.json");
        StringBuilder sb = new StringBuilder();
        BufferedReader fr = new BufferedReader(new FileReader(f));
        String len = "";
        while ((len = fr.readLine()) != null) {
            sb.append(len);
        }
        fr.close();
        formparams.add(new BasicNameValuePair("json", sb.toString()));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String transaction() throws IOException {
        String url = api + "/api/app/account/transactionList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("startTime", ""));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String refundList() throws IOException {
        String url = api + "/api/app/2b/order/refundList";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
//        formparams.add(new BasicNameValuePair("state", "REFUSEAGENT"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String orderEdit() throws IOException {
        String url = api + "/api/app/2b/order/orderEdit";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("orderIds", "6378271"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }


    private static String queryItemByOuterIds() throws IOException {
        String url = api + "/api/app/2b/order/queryItemByOuterIds";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("outerIds", "2629275"));
        return PostUtil.httpPostWithHeader(url, formparams, token);
    }

    private static String hotword() throws IOException {
        String url = api + "/pc/hotWordAdd";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("name", "sssssss"));
        formparams.add(new BasicNameValuePair("userId", "489724"));
        formparams.add(new BasicNameValuePair("userIp", "172.16.0.55"));
        formparams.add(new BasicNameValuePair("source", "e3e3"));
        formparams.add(new BasicNameValuePair("resultNum", "2"));
        return PostUtil.httpPost(url, formparams);

    }

    private static String accountCancel() throws IOException {
        String url = api + "/api/app/user/accountCancel";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("reason", aes.encrypt("1")));
        formparams.add(new BasicNameValuePair("mobile", "1231232"));
        return PostUtil.httpPostWithHeader(url, formparams, token);

    }

    private static String login() throws IOException {
        String url = api + "/login";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("loginType", aes.encrypt("1")));
        formparams.add(new BasicNameValuePair("username", aes.encrypt("alber20119")));
        //bScF4RoOgl20
        formparams.add(new BasicNameValuePair("password", aes.encrypt("123456")));
//        formparams.add(new BasicNameValuePair("password", aes.encrypt("bScF4RoOgl20")));
//        formparams.add(new BasicNameValuePair("phone", aes.encrypt("152030969")));
//        formparams.add(new BasicNameValuePair("username", "幸运baby"));
        return PostUtil.httpPost(url, formparams);
    }

    private static String loginTest() throws IOException {
        String url = api + "/loginTest";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        formparams.add(new BasicNameValuePair("loginType", "1"));
        formparams.add(new BasicNameValuePair("username", "15803096943|994447"));
        formparams.add(new BasicNameValuePair("password", "7740+123123"));
        formparams.add(new BasicNameValuePair("phone", aes.encrypt("152030969")));
//        formparams.add(new BasicNameValuePair("username", "幸运baby"));
//        formparams.add(new BasicNameValuePair("vcode", aes.encrypt("3484")));
        return PostUtil.httpPost(url, formparams);

    }

    private static String orderList() throws IOException {
        String url = api + "/api/app/2b/order/list";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
//        formparams.add(new BasicNameValuePair("orderNo", "320"));
        formparams.add(new BasicNameValuePair("state", ""));
        return PostUtil.httpPostWithHeader(url, formparams, token);

    }

    private static String createOrder() throws IOException {
        String url = api + "/api/app/2b/order/createOrder";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        AES aes = new AES("2016.01_go2plus_chengdu_china");
        File f = new File(System.getProperty("user.dir") + System.getProperty("file.separator") + "createOrderE3.json");
        StringBuilder sb = new StringBuilder();
        BufferedReader fr = new BufferedReader(new FileReader(f));
        String len = "";
        while ((len = fr.readLine()) != null) {
            sb.append(len);
        }
        fr.close();
        formparams.add(new BasicNameValuePair("outPlatform", "3"));
        formparams.add(new BasicNameValuePair("json", sb.toString()));
        formparams.add(new BasicNameValuePair("token", token));
        return PostUtil.httpPostWithHeader(url, formparams, token);

    }


    private static String getValiCode() throws IOException {
        String url = api + "/getValiCode";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        AES aes = new AES("2016.01_go2plus_chengdu_china");
        formparams.add(new BasicNameValuePair("phone", aes.encrypt("152030969")));
        return PostUtil.httpPost(url, formparams);
    }


    private static String checkVCode() throws IOException {
        String url = api + "/checkVCode";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        AES aes = new AES("2016.01_go2plus_chengdu_china");
        formparams.add(new BasicNameValuePair("phone", aes.encrypt("15803096943")));
        formparams.add(new BasicNameValuePair("vcode", aes.encrypt("2094")));
        return PostUtil.httpPost(url, formparams);
    }

    private static String oneClickLogin() throws IOException {
        String url = api + "/oneClickLogin";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        AES aes = new AES("2016.01_go2plus_chengdu_china");
        formparams.add(new BasicNameValuePair("phone", aes.encrypt("15803096953")));
        formparams.add(new BasicNameValuePair("device", aes.encrypt("ios")));
        return PostUtil.httpPost(url, formparams);
    }

    private static String phoneVali() throws IOException {
        String url = api + "/phoneVali";
        List<NameValuePair> formparams = new ArrayList<NameValuePair>();
        AES aes = new AES("2016.01_go2plus_chengdu_china");
        formparams.add(new BasicNameValuePair("mobile", aes.encrypt("13636620346")));
        formparams.add(new BasicNameValuePair("vCode", aes.encrypt("0337")));
        return PostUtil.httpPost(url, formparams);
    }




}
